#include "List.cpp"
#include <iostream>

struct Point {
	double x, y;
};

int main(int argc, char ** argv) {
	List<int> l;

	std::cout << std::endl << "Adding elements..." << std::endl;
	for (int i = 0; i < 10; i++) {
		if (i % 2 == 0) {
			l.push_front( i );
		}
		else {
			l.push_back( i );
		}
		l.print();
	}
	
	std::cout << std::endl << "Deleting elements..." << std::endl;
	for (int i = 0; i < 10; i++) {
		if (i % 2 == 0) {
			l.pop_front( );
		}
		else {
			l.pop_back( );
		}
		l.print();
	}

	List<Point> points;
	
	Point p;
	p.x = 12.97;
	p.y = 35.16;
	points.push_front( p );
	
	List<Point>::Iterator i = points.begin();
	std::cout << "Point: (" << i->x << ", " << i->y << ")" << std::endl;
	
	return 0;
}